package cn.tedu.shoot;

import java.awt.image.BufferedImage;

//小敌机
public class Airplane extends FlyingObject implements EnemyScore {
	private int speed; // 移动速度
	public Airplane() {
		super(92, 70);
		speed = 2;
	}
   
	public void step() {
		y+=speed;//y+(向下）
	}
	 int index=1;
	public BufferedImage getImage() {
		if(isLive()) {
			return Images.airs[0];
		}else if(isDead()) {
			BufferedImage img=Images.airs[index++];
			if(index==Images.airs.length) {
				state=REMOVE;
				}
			return img;
		}
		return null;			
		}
	public int getScore() {
		return 1;
	}
	}


